Add an Unsupported EtherCAT Device


  • This procedure is for advanced users only.

When your project contains EtherCAT devices not supported by KAS, you must create the configuration using an external tool, and perform these steps:

  1. Get the AKD device description ESI file from the official AKD distribution.
  2. Verify all the device description ESI files are available for the external tool.
  3. Use the external tool and do all the configuration, including these points:
    1. Set the Cycle Time.
    2. Turn on the distributed clocks option for all slave drives in order to share a global system time through EtherCAT.
    3. Assign PDO to each drive (inputs and outputs).
    4. Set the mode of operation of the drives into position mode.
    5. Insert variable names and do the mapping (see Map PLC Variables).
  4. Use the external tool to export the ENI description file.
  5. In KAS, import the ENI file describing all the EtherCAT devices included in the project.
    See ENI File tab.

  • Importing an external ENI file overrides all EtherCAT project device information and configuration settings in the KAS-IDE.

    These views and configurations are not applicable when using an imported ENI file:

    • Project View: All devices located under the EtherCAT node.
    • EtherCAT Device View tabs:
      • General Properties
      • PDO Selection/Mapping
      • Distributed Clock
      • CoE Init-Commands
    • Slice I/O Properties
    • Mapping PLC Variables to Slice I/O or PDO objects.

    Information displayed in the views may not match the imported ENI file.

Modify the EtherCAT Image in Cyclic Mode

In the application program, when integrating non-standard EtherCAT devices, use these function blocks to update the EtherCAT frame.

See EtherCAT Motion Bus Concepts.

Configure the EtherCAT Device

Use these Functions Blocks:

Map PLC Variables

When you use an XML network description file generated with an external configurator, you need to add special tags to the PDO names to ensure the PLC variables can be mapped to IO channels.

The tags must comply with this convention:

@Scope.VariableName+StartBit-Size

Field

Description

@

Prefix with character @ the PLC variable names of each of the image attributes that must be mapped.

Scope

Scope can be:

  • (Global)
  • (Retain Variables)
    • Parentheses must surround the scope when it is Global or Retain.
  • Program Name
    • Even for the case of nested child SFC programs, the variables still belong to a unique, well-defined subprogram.

+StartBit

Optional: Integer that defines the bit from which the data must be written or read from the PLC variable.

-Size

Optional: Integer that defines the number of consecutive bits in the image which must be copied to/from the PLC variable.

When present, this setting has precedence over the <BitSize> tag of the XML file.

Examples

(Global).MachineState
(Global).bLedStatus:0-1
(Global).bLedStatus:1-1
(Global).myINT:+4
main.variable:3+4-8

  • This convention is applicable for simple variables.
    KAS does not yet support mapping for Structs and Arrays.

Concept Link IconSee Also